﻿<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                    xmlns:treemap="clr-namespace:Silverlight.Treemap"
                    xmlns:datavis="clr-namespace:Silverlight.Treemap.Controls.DataVisualization.Toolkit;assembly=Silverlight.Treemap"
                    xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d"
                    >
    <Style TargetType="treemap:Chart">
        
        <Setter Property="ChartAreaStyle">
            <Setter.Value>
                <Style TargetType="Canvas">
                    <Setter Property="Background" Value="Red"/>
                </Style>
            </Setter.Value>
        </Setter>
        
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="treemap:Chart">
                    <Canvas x:Name="WorkArea"
                            Style="{TemplateBinding ChartAreaStyle}">
                    </Canvas>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
        <Setter Property="Background" Value="#FFE81919"/>
        <Setter Property="Foreground" Value="#FFE20F0F"/>
    </Style>

    <Style TargetType="treemap:ChartSector">
        <Setter Property="StylePalette">
            <Setter.Value>
                <datavis:StylePalette>
                    <!--Blue-->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FFB9D6F7" />
                                    <GradientStop Color="#FF284B70"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                    <!--Red-->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FFFBB7B5" />
                                    <GradientStop Color="#FF702828"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                    <!-- Light Green -->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FFB8C0AC" />
                                    <GradientStop Color="#FF5F7143"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                    <!-- Yellow -->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FFFDE79C" />
                                    <GradientStop Color="#FFF6BC0C"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                    <!-- Indigo -->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FFA9A3BD" />
                                    <GradientStop Color="#FF382C6C"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                    <!-- Magenta -->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FFB1A1B1" />
                                    <GradientStop Color="#FF50224F"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                    <!-- Dark Green -->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FF9DC2B3" />
                                    <GradientStop Color="#FF1D7554"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                    <!--Gray Shade-->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FFB5B5B5" />
                                    <GradientStop Color="#FF4C4C4C"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                    <!--Blue-->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FF98C1DC" />
                                    <GradientStop Color="#FF0271AE"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                    <!-- Brown -->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FFC1C0AE" />
                                    <GradientStop Color="#FF706E41"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                    <!--Cyan-->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FFADBDC0" />
                                    <GradientStop Color="#FF446A73"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                    <!-- Special Blue -->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FF2F8CE2" />
                                    <GradientStop Color="#FF0C3E69"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                    <!--Gray Shade 2-->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FFDCDCDC" />
                                    <GradientStop Color="#FF757575"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                    <!--Gray Shade 3-->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FFF4F4F4" />
                                    <GradientStop Color="#FFB7B7B7"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                    <!--Gray Shade 4-->
                    <Style TargetType="Canvas">
                        <Setter Property="Background">
                            <Setter.Value>
                                <RadialGradientBrush>
                                    <RadialGradientBrush.RelativeTransform>
                                        <TransformGroup>
                                            <ScaleTransform CenterX="0.5"
                                                            CenterY="0.5"
                                                            ScaleX="2.09"
                                                            ScaleY="1.819" />
                                            <TranslateTransform X="-0.425"
                                                                Y="-0.486" />
                                        </TransformGroup>
                                    </RadialGradientBrush.RelativeTransform>
                                    <GradientStop Color="#FFF4F4F4" />
                                    <GradientStop Color="#FFA3A3A3"
                                                  Offset="1" />
                                </RadialGradientBrush>
                            </Setter.Value>
                        </Setter>
                    </Style>
                </datavis:StylePalette>
            </Setter.Value>
        </Setter>
        <Setter Property="FolderStyle">
            <Setter.Value>
                <Style TargetType="Canvas">
                    <Setter Property="Background"
                            Value="Green" />
                </Style>
            </Setter.Value>
        </Setter>
        <Setter Property="FileStyle">
            <Setter.Value>
                <Style TargetType="Canvas">
                    <Setter Property="Background"
                            Value="Yellow" />
                </Style>
            </Setter.Value>
        </Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="treemap:ChartSector">
                    <Border BorderThickness="1"
                            BorderBrush="Gray"
                            Margin="10,10,10,10"
                            Background="#FFADD8E6" d:DesignWidth="121" d:DesignHeight="112">
                        <Grid>
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="*" />
                            </Grid.RowDefinitions>
                            <Canvas Grid.Row="1"
                                    x:Name="ChildWorkArea"
                                     />

                            <TextBlock Text="{TemplateBinding IndependentValue}"
                                       Margin="5" />
                        </Grid>
                    </Border>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
        <Setter Property="Foreground" Value="#FF4D4C4C"/>
    </Style>
</ResourceDictionary>
